import { Button, message } from 'antd'
import React from 'react'
import { useHistory } from 'react-router-dom'
import { E_ROUTE_PATH } from '../../router/route-path'
import './Home.less'

export default function Home() {
  const history = useHistory()
  function buy() {
    message.info('等待接入BOSS购买页面')
  }

  function register() {
    history.push(E_ROUTE_PATH.REGISTER)
  }

  return (
    <div className="home">
      <div className="title">轻松开课，就选小课堂</div>
      <div className="app-desc" />
      <div className="btn-node">
        <Button type="primary" shape="round" className="btn-buy custom-btn" onClick={buy}>
          立即购买
        </Button>
        <Button type="primary" shape="round" className="btn-register  custom-btn" onClick={register}>
          申请试用
        </Button>
      </div>
    </div>
  )
}
